package com.py.classloader.test;

import com.py.classloader.test.BusineseException;

public class BusineseException extends RuntimeException {
	private static final long serialVersionUID = 8304692784297155877L;

	private int errorCode = -1;
	private String errorMsg;
	
	public BusineseException(int errorCode) {
		this.errorCode = errorCode;
	}
	
	public BusineseException(int errorCode, String errorMsg) {
		super(errorMsg);
		this.errorCode = errorCode;
		this.errorMsg = errorMsg;
	}
	
	public int getErrorCode() {
		return this.errorCode;
	}
	
	public String getErrorMsg() {
		return this.errorMsg;
	}
	
	@Override
	public Throwable fillInStackTrace() {//重载添加异常运行栈方法，提高异常处理效率
		return this;
	}
 
}
